#include "ff_utils.h"

using namespace std;
using namespace feifei;

E_ffState RtnState;
int ErrorCnt = 0;
void ChkRtn()
{
	if (RtnState != E_ffState::SUCCESS)
		ErrorCnt++;
}

int main()
{
	LOG("workspace test");

	std::string path = get_curr_path();
	LOG("curr path is: %s", path.c_str());

	path = TEST_WORK_SPACE;
	RtnState = set_work_path(path);
	ChkRtn();

	path += DIR_SPT;
	path += "new_folder_test";
	RtnState = set_work_path(path);
	ChkRtn();

	path = "XX:\\test invalid path";
	RtnState = set_work_path(path);
	if (RtnState != E_ffState::RTN_ERR)
		ErrorCnt++;

	return ErrorCnt;
}
